const TagModel = require("../model/TagModel")

const TagService = {
    getList:async () => {
        //联系role集合查询
        return await TagModel.find()
    },
    addList:async (body) => {
        return await TagModel.create(body)
    },
    deleteList:async(id) => {
        return await TagModel.findByIdAndDelete(id)
    },
    updateList:async(id,body) => {
        return await TagModel.findByIdAndUpdate(id,body)
    }
}
module.exports = TagService